package cn.net.wanji.job;

import cn.net.wanji.entity.EventCar;
import cn.net.wanji.mapper.MonitorMapper;
import cn.net.wanji.utils.StringUtils;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.List;

import static cn.net.wanji.job.RefreshGantryDataJob.gantryFlagInfoMap;
import static cn.net.wanji.utils.TimeUtils.calculateMinutesDifference;

@Slf4j(topic = "定时处理表【RefreshTableDataJob】")
@EnableScheduling
@Component
public class RefreshTableDataJob {

    @Autowired
    private MonitorMapper monitorMapper;

    @Scheduled(fixedRateString = "60000")
    public void updateEvent() {
        monitorMapper.updateEventInfo();
    }
}
